import java.sql.SQLOutput;
import java.util.InputMismatchException;
import java.util.Scanner;

public class test{

    int a;
    String b;
    public void demo1() throws InputMismatchException,NullPointerException{
        Scanner sc = new Scanner(System.in);

        System.out.print("请输入int：");
        a = sc.nextInt();
        System.out.println("a ="+a);
    }

    public  void demo2() throws NullPointerException{
        System.out.println(b.length());
    }

    public static void main(String[] args) {
        test t = new test();
        t.demo1();
        t.demo2();

    }

}
